package com.xzq.erp.service;

import com.xzq.erp.domain.dto.PageDTO;
import com.xzq.erp.domain.dto.WarehouseDTO;
import com.xzq.erp.domain.po.Warehouse;
import com.baomidou.mybatisplus.extension.service.IService;
import com.xzq.erp.domain.query.WarehousePageQuery;
import com.xzq.erp.domain.vo.IdAndNameVO;
import com.xzq.erp.domain.vo.ProductStockListVO;
import com.xzq.erp.domain.vo.ProductStockVO;
import com.xzq.erp.domain.vo.WarehouseVO;

import java.util.List;

/**
 * <p>
 * 仓库表 服务类
 * </p>
 *
 * @author xzq
 * @since 2025-05-26
 */
public interface IWarehouseService extends IService<Warehouse> {

    /**
     * 查询仓库列表
     * @return
     */
    List<IdAndNameVO> getWarehouseList();

    /**
     * 分页查询仓库列表
     * @param query
     * @return
     */
    PageDTO<WarehouseVO> getWarehousePageList(WarehousePageQuery query);

    /**
     * 添加仓库
     * @param warehouseDTO
     */
    void addWarehouse(WarehouseDTO warehouseDTO);

    /**
     * 修改仓库
     * @param warehouseDTO
     */
    void updateWarehouse(WarehouseDTO warehouseDTO);

    /**
     * 查询仓库详情
     * @param id
     * @return
     */
    WarehouseVO getWarehouseById(Long id);

    /**
     * 查询仓库库存
     * @param warehouseId
     * @return
     */
    List<ProductStockVO> getWarehouseStock(Long warehouseId);
}
